<?php
/*{{{LICENSE
+-----------------------------------------------------------------------+
| blogsender                                                            |
+-----------------------------------------------------------------------+
| This program is free software; you can redistribute it and/or modify  |
| it under the terms of the GNU General Public License as published by  |
| the Free Software Foundation. You should have received a copy of the  |
| GNU General Public License along with this program.  If not, see      |
| http://www.gnu.org/licenses/.                                         |
| Copyright (C) 2008-2009. All Rights Reserved.                         |
+-----------------------------------------------------------------------+
| Supports: http://code.google.com/p/blogsender/                        |
+-----------------------------------------------------------------------+
}}}*/

/**
 * @package blogsender
 */


require_once(BS_ROOT."/lib/SHttp.class.php");

class sender extends SHttp{
	
	static $cookies=array();

	function post($url,$params=array()){
		$httpResponse = parent::post($url,$params,self::$cookies,true);
		self::$cookies = array_merge(self::$cookies ,parent::cookie_parse($httpResponse['header']));
		return $httpResponse;
	}


	function get($url,$params=array()){
		$httpResponse = parent::get($url,$params,self::$cookies,true);
		self::$cookies = array_merge(self::$cookies ,parent::cookie_parse($httpResponse['header']));
		return $httpResponse;
	}

}